home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / std / c++ / 242 < prev    next >
Encoding:
Internet Message Format  |  1996-08-06  |  1.8 KB

  1. Path: engnews1.Eng.Sun.COM!taumet!clamage
  2. From: "Nathan Myers, http://www.cantrip.org/" <ncm@cantrip.org>
  3. Newsgroups: comp.std.c++
  4. Subject: Re: Time representations
  5. Date: 2 Feb 1996 15:49:18 GMT
  6. Organization: The Cantrip Cooperative
  7. Approved: clamage@eng.sun.com (comp.std.c++)
  8. Message-ID: <31121F55.139E@cantrip.org>
  9. References: <4emq2k$ecu@news.duke.edu>
  10. NNTP-Posting-Host: taumet.eng.sun.com
  11. Mime-Version: 1.0
  12. Content-Type: text/plain; charset="us-ascii"
  13. Content-Transfer-Encoding: 7bit
  14. X-Nntp-Posting-Host: ncm.vip.best.com
  15. X-Mailer: Mozilla 2.0b6a (X11; I; SunOS 5.4 sun4m)
  16. X-Lines: 24
  17. Content-Length: 998
  18. Originator: clamage@taumet
  19.  
  20. Max TenEyck Woodbury wrote:
  21. >     The C++ standard incorporates the C standard for dates and times
  22. > by reference.  There are at least three problems with the 'struct tm'
  23. > definition in that standard.
  24. > ...
  25. >     Second, there are cultures that operate on a lunar calendar,
  26. > rather than on the Gregorian calendar.  They have 13 or more months
  27. > a year.  The tm_mon range needs to reflect this.
  28. >     Third, there are cultures that do not start their year on January
  29. > 1st.  This has an impact on the definition of tm_yday even though
  30. > its range will not change.  There is a similar definitional problem
  31. > with tm_year. ...
  32.  
  33. The C++ Library (Draft!) standard is not as restrictive
  34. as Woodbury suggests.  It is capable of representing 
  35. Gregorian dates, but does not in any way enforce them.
  36. It does expect that any other date is convertible into
  37. a Gregorian date (and a Julian), but that's a much weaker
  38. restriction.
  39.  
  40. Nathan Myers
  41. ncm@cantrip.org   http://www.cantrip.org/    <-- works now.
  42.  
  43. [ comp.std.c++ is moderated.  Submission address: std-c++@ncar.ucar.edu.
  44.   Contact address: std-c++-request@ncar.ucar.edu.  The moderation policy is
  45.   summarized in http://reality.sgi.com/employees/austern_mti/std-c++/policy.html
  46. ]
  47.